let obj: object;
obj = {
  name: "zhangsan",
  age: 18,
};

let o1: object;
o1 = {};
o1 = Object.prototype;
console.log(o1);

// 设置ts中对象的属性值（属性之间隔离可以用分号也可以用逗号）
let o2: { name: string; age: number };
o2 = {
  name: "zhangsan",
  age: 18,
};

console.log(o2);

// url为对象可选属性（属性之间隔离可以用分号也可以用逗号）
let o3:{name:string, age:number, url ?:string};
o3 = {
  name: "zhangsan",
  age: 18,
  url:'www.baidu.com'
};
console.log(o3);
